package com.shenjies88.practice.designpatterns;

import com.shenjies88.practice.designpatterns.interfaces.PlugA;

public class MobilePhone {

    public void chargeFromPlugA(PlugA plugA) {
        if (plugA == null) {
            throw new NullPointerException("plug is not null!");
        }
        plugA.chargeFromPlugA();
    }
}
